<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8" import="java.util.*"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %><%--jstl을 쓰기 위해 사용 --%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %><%--숫자 포맷을 사용하기 위해 사용 --%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions"  prefix="fn"%><%--함수들을 이용하기 위해 사용 --%>
<%@ taglib prefix="c-rt" uri="http://java.sun.com/jstl/core_rt" %>  <%-- ie버전 확인에 쓰기 위해 씀 --%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<!--<script type="text/javascript" src="script/sms_riskI_script.js"></script>-->
<style type="text/css">
div#centerDiv{margin-left: 10px; }
</style>
<!--[if IE 6]>
<style type="text/css">
div#centerDiv{margin-left: 5px; }
</style>
<![endif]-->
</head>
<body onload="document.getElementById('mode').value='mastate_insert'">
<div class="box">
      		<h4 class="white" >
      		<span class="align-left">RA정보-컨테이너 등록 </span>
      		<span class="align-right">마감상태(정보식별및평가) :
	      		<c:choose>
	      			<c:when test="${sessionScope.magamSession[0].state =='Y'}">
	      				 마감
	      			</c:when>
	      			<c:otherwise>
	      				 착수
	      			</c:otherwise>
	      		</c:choose>
      		</span>
      		
      		</h4>
      		<form name="riskIForm" action="riskIAction.do" method="post">
        	<input type="hidden" name="mode" id="mode" value="mastate_insert"></input>
        	<input type="hidden" name="pro_id"  id="pro_id" value="${sessionScope.lastProId }"></input>
		 <table class="table-long" style="width: 100%">
      			<tfoot>
      				<tr><td class="spaceLine"></td></tr>
      				<tr>
      					<td>
      						<div class="align-right">
	                        	<c:choose>
	                        		<c:when test="${sessionScope.magamSession[0].state !='Y'}">
	                        		<!-- 마감 현황이 유무 판별(Y 시 입력 불가) -->
	                        			<a href="#" class="button lastButton" onclick="javascript: riskIDeleteCont()"><span>삭제</span></a>
	                        		</c:when>
	                        		<c:otherwise>	
	                        			<a href="#" class="button1 lastButton addMargin" onclick="return false"><span>삭제</span></a>
	                        		</c:otherwise>
	                        	</c:choose>
	                        	<a href="#" class="button" onclick="javascript: riskICancleWriteTab('mrainfo', 2)"><span>닫기</span></a>
                      	  </div>
      					</td>
      				</tr>
      			</tfoot>
      		</table>
        <div class="box-container1" style="width: 36%; float:left; margin-left: 5px;">     		
        
        	<table class="table-long" style="width: 100%">
        		<colgroup>
        			<col width="75px"/>
        			<col/>
        		</colgroup>
      			<tfoot>
      				<tr>
      					<td colspan="2">
      					<div class="align-left subjectTitle"> ■ 자산유형분류기준</div>
      					</td>
      				</tr>
      				<tr>
      					<td style="border-top:none; background-color: #6f797b; color: #fff; text-align: center; vertical-align: middle;">컨테이너명</td>
      					<td>
      					<input type="text" name="racont_nm" id="racont_nm" maxlength="30"  style="width: 65%" onkeyup="javascript: inputCheckSpecial(this)"></input>
      					
     						<c:choose>
                        		<c:when test="${sessionScope.magamSession[0].state !='Y'}">
                        		<!-- 마감 현황이 유무 판별(Y 시 입력 불가) -->
                        			<a href="#" class="button" style="margin: 0" onclick="mastate_insert()"><span>등록</span></a>
                        		</c:when>
                        		<c:otherwise>	
                        			<a href="#" class="button1" style="margin: 0" onclick="return false"><span>등록</span></a>
                        		</c:otherwise>
                        	</c:choose>
      					</td>
      				</tr>
      				<tr><td class="spaceLine" colspan="2"></td></tr>
      			</tfoot>
      		</table>
      		<table class="table-long" style="width: 100%;">
      			<colgroup>
      				<col width="40px"/>
					<col width="40px"/>
					<col width="60px"/>
					<col width=""/>
					<col width="15px"/>
				</colgroup>
      			<thead>
      				<tr>	
      					<td class="col-chk"><input type='checkbox' name='checkAll' onclick="javascript: selectAll()" class="chkCursor"></input></td>
      					<td>
      						순번
      					</td>
      					<td>구분</td>
      					<td>
      						컨테이너명
      					</td>
      					<td></td>
      				</tr>
      			</thead>
      		</table>
      		<div class="scrollDIV" style="width: 100%; height: 448px;">
      		<table class="table-long" style="width: 100%;"  id="countTrTable">
      			<colgroup>
					<col width="40px"/>
					<col width="40px"/>
					<col width="60px"/>
					<col width=""/>
					<col width="15px"/>
				</colgroup>
      			<tbody>
      				<c:choose>
                    	<c:when test="${fn:length(traList)!= 0}">
                       	<c:forEach var="list" items="${requestScope.traList}" varStatus="status">
	                    			<%--
	                    			<tr onmouseover="ChangeBackground(this,'over','${status.index}');" onmouseout="ChangeBackground(this,'out','${status.index}');" class="odd">
	                    			 <tr <c:if test="${status.index%2==0 }">class="odd"</c:if> onmouseover="ChangeBackground(this,'over','${status.index}');" onmouseout="ChangeBackground(this,'out','${status.index}');">    //setRaIdNm('${list.rainfo_id}','${list.rainfo_nm }','${sessionScope.magamSession[0].state }'); 
	                    			 --%>
	                    	<tr id="trArea${status.index+1 }" <c:if test="${status.index%2==0 }">class="odd"</c:if> onclick="javascript: setContInfoAjax('${list.racont_nm }','${list.base_lev1 }');" onmouseover="ChangeBackground(this,'over','${status.index}');" onmouseout="ChangeBackground(this,'out','${status.index}');">
	                    	
                    			<td class="col-chk"><input type="checkbox" name="check" id="check00${status.index+1 }"  value='${list.racont_nm}' class="chkCursor"></input></td>
                    			<td>
                    				${status.index+1 }
                    			</td>
                    			<td>
                    				<div class="ellipsis"  style="width:100%;" title="${list.gubun }">${list.gubun }</div>
                    			</td>
                    			<td>
                    				<div class="ellipsis"  style="width:100%;" title="${list.racont_nm }">${list.racont_nm }</div>
                    			</td>
                    			
                    			
	   					 	<td></td>
                    		</tr>
	                    		
                    	</c:forEach>
                    	</c:when>
                    	<c:otherwise>
                    		<tr class="odd">
								<td colspan="5" class="noDataTD">-데이터가 없습니다-</td>
							</tr>
                    	</c:otherwise>
                    	</c:choose>
      			</tbody>
      		</table>  	
      		</div>
      	</div><!-- end of div.box-container1 -->
      	
      	<!-- 세로 구분선 -->
      	<div class="box-container1" style="width: 1px; float:left; border-left : 1px solid #dedede; margin-left: 5px; height: 524px"></div>
      	
      	<!-- 자산보안등급평가기준 -->
      	<div class="box-container1" style="width: 24%; float:left; margin-left: 3px" id="centerDiv">     		
        	<table class="table-long" style="width: 100%">
      			<tfoot>
      				<tr>
      					<td>
      						<div class="align-left subjectTitle"> ■ 자산보안 유형선택</div>
      					</td>
      				</tr>
      				<tr><td class="spaceLine"></td></tr>
      			</tfoot>
      		</table>
      		<table class="table-long" style="width: 100%">
      			<colgroup>
						<col width="40px"/>
						<col width=""/>
						<col width="15px"/>
			</colgroup>
      			<thead>
      				<tr>
      					<td class="col-chk"></td>
      					<td style="padding-top: 5px;padding-bottom: 4px">자산유형</td>
    					<td></td>
      				</tr>
      			</thead>
      		</table>
      		<div class="scrollDIV" style="width: 100%; height: 476px;">
      		<table class="table-long" style="width: 100%">
      			<colgroup>
						<col width="40px"/>
						<col width=""/>
						<col width="15px"/>
			</colgroup>
      			<tbody>
      				<c:choose>
                    	<c:when test="${fn:length(makList)!= 0}">
                       	<c:forEach var="list" items="${requestScope.makList}" varStatus="status">
	                    			<%--
	                    			<tr onmouseover="ChangeBackground(this,'over','${status.index}');" onmouseout="ChangeBackground(this,'out','${status.index}');" class="odd">
	                    			 --%>
	                    			  <tr <c:if test="${status.index%2==0 }">class="odd"</c:if>>
		                    			<td class="col-chk"><input type="radio" name="check1" id="check10${status.index+1 }"  value='${list.base_lev1}' class="chkCursor"></input></td>
		                    			<td>
		                    				<div class="ellipsis"  style="width:100%;" title='${list.ak_nm2 }'>${list.ak_nm2 }</div>
		                    			</td>
			   					 	<td></td>
		                    		</tr>
                    	</c:forEach>
                    	</c:when>
                    	<c:otherwise>
                    		<tr class="odd">
								<td colspan="3" class="noDataTD">-데이터가 없습니다-</td>
							</tr>
                    	</c:otherwise>
                    	</c:choose>
      			</tbody>
      		</table>  	
      		</div>
      	</div><!-- end of div.box-container1 -->
      	<!-- 세로 구분선 -->
      	<div class="box-container1" style="width: 1px; float:left; border-left : 1px solid #dedede; margin-left: 4px; height: 524px"></div>
      	
      	<%--자산기밀등급 분류 --%>
        <div class="box-container1"style="width: 36%; float:right; margin-right: 5px;">     		
        	<table class="table-long" style="width: 100%">
      			<tfoot>
      				<tr>
      					<td>
      					<div class="align-left subjectTitle"> ■ 정보선택</div>
      					</td>
      				</tr>
      				<tr><td class="spaceLine"></td></tr>
      			</tfoot>
      		</table>
      		<table class="table-long" style="width: 100%">
      			<colgroup>
					<col width="40px"/>
					<col/>
					<col width="15px"/>
				</colgroup>
      			<thead>
      				<tr>
      					<td class="col-chk"><input type='checkbox' name='checkAll2' onclick="javascript: selectAll2()" class="chkCursor"></input></td>
      					<td>정보목록</td>
      					<td></td>
      				</tr>
      			</thead>
      		</table>
      		<div class="scrollDIV" style="width: 100%; height: 476px;">
      		<table class="table-long" style="width: 100%">
      			<colgroup>
					<col width="40px"/>
					<col/>
					<col width="15px"/>
				</colgroup>
      			<tbody>
      				<c:choose>
                    	<c:when test="${fn:length(mraList)!= 0}">
                       	<c:forEach var="list" items="${requestScope.mraList}" varStatus="status">
	                    			<%--
	                    			<tr onmouseover="ChangeBackground(this,'over','${status.index}');" onmouseout="ChangeBackground(this,'out','${status.index}');" class="odd">
	                    			 --%>
                   			 <tr <c:if test="${status.index%2==0 }">class="odd"</c:if>>
                    			<td class="col-chk"><input type="checkbox" name="check2" id="check20${status.index+1 }"  value='${list.rainfo_id}' class="chkCursor"></input></td>
                    			<td>
                    				<div class="ellipsis"  style="width:100%;" title='${list.rainfo_nm }'>${list.rainfo_nm }</div>
                    			</td>
	   					 	<td></td>
                    		</tr>
                    		
                    	</c:forEach>
                    	</c:when>
                    	<c:otherwise>
                    		<tr class="odd">
								<td colspan="3" class="noDataTD">-데이터가 없습니다-</td>
							</tr>
                    	</c:otherwise>
                    	</c:choose>
      			</tbody>
      		</table>  	
      		</div>
      	</div><!-- end of div.box-container1 -->
      	
      	
      	
      		</form>
      	</div> <!-- end of div.box -->
</body>
</html>